import request from '@/utils/request'

/**
 * 分页参数查询学习经历数据
 * @param {*} pageQuery 
 * @returns 
 */
export const getStudyExperiencePageQueryService = (pageQuery) => {
    return request.get('/admin/experience/page', {
        params: pageQuery
    })
}

/**
 * 新增学习经历
 * @param {*} query 
 * @returns 
 */
export const addStudyExperienceService = (query) => {
    return request.post('/admin/experience', query)
}

/**
 * 修改学习经历状态
 * @param {*} query 
 * @returns 
 */
export const updateStatusStudyExperienceService = (query) => {
    return request.put('/admin/experience/status', query)
}

/**
 * 批量删除
 * @param {*} ids 
 * @returns 
 */
export const deleteBatchStudyExperienceService = (ids) => {
    return request.delete('/admin/experience', {
        data: ids
    })
}

/**
 * 根据id查询学习经历数据
 * @param {*} id 
 * @returns 
 */
export const getStudyExperienceByIdSerivce = (id) => {
    return request.get(`/admin/experience/${id}`)
}

/**
 * 修改学习经历
 * @param {*} query 
 * @returns 
 */
export const updateStudyExperienceService = (query) => {
    return request.put('/admin/experience', query)
}